package com.ebidding.Utils;


import com.ebidding.entity.Orders;
import org.springframework.amqp.rabbit.annotation.RabbitListener;
import org.springframework.stereotype.Component;

@Component
public class HelloReceive {

    /**
     * 测试下mq是否有顺序执行？并发1000消息，消费者是如何消费？，观察下Rabbitmq的监控界面
     * @param str
     */
    @RabbitListener(queues="topic.message")    //监听器监听指定的Queue
    public void process1(String str) {
        System.out.println("message:"+str);
    }
    @RabbitListener(queues="topic.messages")    //监听器监听指定的Queue
    public void process2(String str) {
        System.out.println("messages:"+str);
    }

}
